import { Navigate } from 'react-router-dom'
import { lazy } from 'react'

//登录页面
const Login = lazy(() => import('../views/login'))
//聊天对话页面
const Chat = lazy(() => import('../views/chat'))

const element = [
	{
		path: 'login',
		element: <Login />
	},
	{
		path: 'chat',
		element: <Chat />
	},
	//严格模式，去掉缺省
	{
		path: '/',
		element: <Navigate to='login' />
	}
]


export default element;
